#define _CRT_SECURE_NO_WARNINGS 1

#include <iostream>
#include <string>
#include <algorithm>
using namespace std;


string Add(const string& s1, const string& s2) {
    int i_1 = s1.size() - 1, i_2 = s2.size() - 1;
    int next = 0;
    string ans;

    while (i_1 >= 0 || i_2 >= 0 || next) {
        int cur = 0;
        if (i_1 >= 0)
            cur += s1[i_1--] - '0';
        if (i_2 >= 0)
            cur += s2[i_2--] - '0';
        cur += next;
        next = cur / 10;
        cur %= 10;
        ans += cur + '0';
    }
    reverse(ans.begin(), ans.end());
    return ans;

}
int main() {

   //  write your code here......
    string s = "9";
    string ans = "0";
    for (int i = 1; i < 10; ++i) {
        if (i == 9)
            cout << endl;
        ans = Add(s, ans);
        s += "9";
    }
    cout << ans << endl;

    /*cout << Add("999", "99") << endl;*/

    return 0;
}